package SEApp.dialogs
{
	import SEApp.boxes.albums.se_albums;
	
	import UIFree.uif_component;
	
	import flash.geom.Rectangle;

	public class se_userPhotosDialog extends se_dialog {
		private var _albums: se_albums;
		public function se_userPhotosDialog(parent:uif_component, awidth:int=0, aheight:int=0, asModal:Boolean=false, canClose:int=2) {
			super(parent, 0, 0, awidth, aheight, asModal, canClose);
		}
		
		protected function createAlbums(uid: String, albums: Array): se_albums {
			var inner: Rectangle = getInner();
			return new se_albums(this, uid, albums, 5, false, inner.x, inner.y, inner.width, inner.height, 0, 'tabBox'); 
		}
		
		public function get albums(): se_albums {
			return _albums;
		} 
		
		public function showPhotos(uid: String, albums: Array): void {
			if (_albums) _albums.dispose();
			_albums = createAlbums(uid, albums);
			show();
		}
	}
}